﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="ingresoAdministrador.aspx.cs" Inherits="WebContratos.ingresoAdministrador" %>

<%@ Register Assembly="DevExpress.Web.ASPxEditors.v10.2, Version=10.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a"
    Namespace="DevExpress.Web.ASPxEditors" TagPrefix="dx" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<%@ Register TagPrefix="cc1" Namespace="BunnyBear" Assembly="msgBox" %>
<%@ Register assembly="DevExpress.Web.ASPxHtmlEditor.v10.2, Version=10.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" namespace="DevExpress.Web.ASPxHtmlEditor" tagprefix="dx" %>
<%@ Register assembly="DevExpress.Web.ASPxSpellChecker.v10.2, Version=10.2.3.0, Culture=neutral, PublicKeyToken=b88d1754d700e49a" namespace="DevExpress.Web.ASPxSpellChecker" tagprefix="dx" %>
<html xmlns="http://www.w3.org/1999/xhtml">
<head id="Head1" runat="server">
    <title>Asignacion de Administrador</title>

    <script type="text/javascript">
    // <![CDATA[
        function phone_InitAndKeyUp(s,e) {
            //document.getElementById("phoneValue").innerHTML=s.GetValue();
        }
        function price_InitAndKeyUp(s,e) {
            document.getElementById("lblMontoSinMas").innerHTML=s.GetValue();
           
        }
    // ]]>
    </script>

    <link rel="stylesheet" type="text/css" media="all" href="css/calendario/themeBlue.css"
        title="Aqua" />
    <link rel="alternate stylesheet" type="text/css" media="all" href="css/calendario/theme(1)Blue.css"
        title="Tiger" />

    <script type="text/javascript" src="js/calendario/calendar.js"></script>
    <script type="text/javascript" src="js/calendario/calendar-en.js"></script>
    <script type="text/javascript" src="js/deluxe/dpopupwindow.js"></script>
    <script type="text/javascript" src="js/deluxe/deluxe-popup-window.js"></script>
    <script type="text/javascript" src="js/FormatValor.js"> </script>
    
        
            <link rel="STYLESHEET" type="text/css" href="js/dhtmlGRID/codebase/dhtmlxgrid.css">
            <link rel="stylesheet" type="text/css" href="js/dhtmlGRID/codebase/skins/dhtmlxgrid_dhx_skyblue.css">
            <link rel="STYLESHEET" type="text/css" href="js/dhtmlGRID/codebase/dhtmlxcalendar.css">

            <script  src="js/dhtmlGRID/codebase/dhtmlxcommon.js"></script>
            <script  src="js/dhtmlGRID/codebase/dhtmlxgrid.js"></script>        
            <script  src="js/dhtmlGRID/codebase/dhtmlxgridcell.js"></script>    

            <script  src="js/dhtmlGRID/codebase/Calen/dhtmlxcalendar.js"></script>    
            <script  src="js/dhtmlGRID/codebase/excells/dhtmlxgrid_excell_dhxcalendar.js"></script>
            <script src="js/dhtmlGRID/codebase/ext/dhtmlxgrid_validation.js" type="text/javascript" charset="utf-8"></script>            <link rel="stylesheet" href="dhtmlx_validation.css" type="text/css" media="screen" title="no title" charset="utf-8">

            <script  src="js/dhtmlGRID/codebase/excells/dhtmlxgrid_excell_cntr.js"></script>
            <script  src="js/dhtmlGRID/codebase/ext/dhtmlxgrid_splt.js"></script>
            <script  src="js/dhtmlGRID/codebase/dhtmlxdataprocessor.js"></script>
            <script  src="js/dhtmlGRID/codebase/ext/dhtmlxgrid_nxml.js"></script>
            <script  src="js/dhtmlGRID/codebase/excells/dhtmlxgrid_excell_link.js"></script>

    <script type="text/javascript">
		
		var oldLink = null;
		
		function setActiveStyleSheet(link, title) 
		{
		  var i, a, main;
		  for(i=0; (a = document.getElementsByTagName("link")[i]); i++) {
			if(a.getAttribute("rel").indexOf("style") != -1 && a.getAttribute("title")) {
			  a.disabled = true;
			  if(a.getAttribute("title") == title) a.disabled = false;
			}
		  }
		  if (oldLink) oldLink.style.fontWeight = 'normal';
		  oldLink = link;
		  link.style.fontWeight = 'bold';
		  return false;
	    }

		function selected(cal, date) {
			  cal.sel.value = date; // just update the date in the input field.
			  if (cal.dateClicked && (cal.sel.id == "sel1" || cal.sel.id == "sel3"))
				// if we add this call we close the calendar on single-click.
				// just to exemplify both cases, we are using this only for the 1st
				// and the 3rd field, while 2nd and 4th will still require double-click.
				cal.callCloseHandler();
		}

		function closeHandler(cal) {
			  cal.hide();                        // hide the calendar
			//  cal.destroy();
			  _dynarch_popupCalendar = null;
		}
            
        
        function showCalendarControl(id, idImage, format, showsTime, showsOtherMonths) 
        {
			  var el = dg.GetEditFormElement('dg1',id);
			  var idIma = dg.GetEditFormElement('dg1',idImage);

			  if (_dynarch_popupCalendar != null) {
				// we already have some calendar created
				_dynarch_popupCalendar.hide();                 // so we hide it first.
			  } else {
				// first-time call, create the calendar.
				var cal = new Calendar(1, null, selected, closeHandler);
				// uncomment the following line to hide the week numbers
				// cal.weekNumbers = false;
				if (typeof showsTime == "string") {
				  cal.showsTime = true;
				  cal.time24 = (showsTime == "24");
				}
				if (showsOtherMonths) {
				  cal.showsOtherMonths = true;
				}
				_dynarch_popupCalendar = cal;                  // remember it in the global var
				cal.setRange(1900, 2070);        // min/max year allowed.
				cal.create();
			  }
			  _dynarch_popupCalendar.setDateFormat(format);    // set the specified date format
			  
			 // alert(el);
			  
			  _dynarch_popupCalendar.parseDate(el.value);      // try to parse the text in field
			  _dynarch_popupCalendar.sel = el;                 // inform it what input field we use

			  // the reference element that we pass to showAtElement is the button that
			  // triggers the calendar.  In this example we align the calendar bottom-right
			  // to the button.
			  _dynarch_popupCalendar.showAtElement(idIma, "Br");//(el.nextSibling, "Br");        // show the calendar

			  return false;
		}
            
			function showCalendar(id, idImage, format, showsTime, showsOtherMonths) {
			  var el = document.getElementById(id);
			  var idIma = document.getElementById(idImage);

			  if (_dynarch_popupCalendar != null) {
				// we already have some calendar created
				_dynarch_popupCalendar.hide();                 // so we hide it first.
			  } else {
				// first-time call, create the calendar.
				var cal = new Calendar(1, null, selected, closeHandler);
				// uncomment the following line to hide the week numbers
				// cal.weekNumbers = false;
				if (typeof showsTime == "string") {
				  cal.showsTime = true;
				  cal.time24 = (showsTime == "24");
				}
				if (showsOtherMonths) {
				  cal.showsOtherMonths = true;
				}
				_dynarch_popupCalendar = cal;                  // remember it in the global var
				cal.setRange(1900, 2070);        // min/max year allowed.
				cal.create();
			  }
			  _dynarch_popupCalendar.setDateFormat(format);    // set the specified date format
			  
			 // alert(el);
			  
			  _dynarch_popupCalendar.parseDate(el.value);      // try to parse the text in field
			  _dynarch_popupCalendar.sel = el;                 // inform it what input field we use

			  // the reference element that we pass to showAtElement is the button that
			  // triggers the calendar.  In this example we align the calendar bottom-right
			  // to the button.
			  _dynarch_popupCalendar.showAtElement(idIma, "Br");//(el.nextSibling, "Br");        // show the calendar

			  return false;
			}

			var MINUTE = 60 * 1000;
			var HOUR = 60 * MINUTE;
			var DAY = 24 * HOUR;
			var WEEK = 7 * DAY;

			// If this handler returns true then the "date" given as
			// parameter will be disabled.  In this example we enable
			// only days within a range of 10 days from the current
			// date.
			// You can use the functions date.getFullYear() -- returns the year
			// as 4 digit number, date.getMonth() -- returns the month as 0..11,
			// and date.getDate() -- returns the date of the month as 1..31, to
			// make heavy calculations here.  However, beware that this function
			// should be very fast, as it is called for each day in a month when
			// the calendar is (re)constructed.
			function isDisabled(date) {
			  var today = new Date();
			  return (Math.abs(date.getTime() - today.getTime()) / DAY) > 10;
			}

			function flatSelected(cal, date) {
			  var el = document.getElementById("preview");
			  el.innerHTML = date;
			}

			function showFlatCalendar() {
			  var parent = document.getElementById("display");

			  // construct a calendar giving only the "selected" handler.
			  var cal = new Calendar(0, null, flatSelected);



			  // hide week numbers
			  cal.weekNumbers = false;

			  // We want some dates to be disabled; see function isDisabled above
			  cal.setDisabledHandler(isDisabled);
			  cal.setDateFormat("%A, %B %e");

			  // this call must be the last as it might use data initialized above; if
			  // we specify a parent, as opposite to the "showCalendar" function above,
			  // then we create a flat calendar -- not popup.  Hidden, though, but...
			  cal.create(parent);

			  // ... we can show it here.
			  cal.show();
			}
	
	
		var hdTipoConsultaJa = '';
		var datoCodContra = '0';
		
		function abrirPopup(c_campo1, c_campo2, valor)
		{
            
           
		  campo1 = document.getElementById(c_campo1).value;
		  campo2 = document.getElementById(c_campo2).value;
		 
		  nomCampo1 = c_campo1;		  
		  nomCampo2 = c_campo2;
		  
		  var longiBusc = 0;
		  var longiBusc1 = 0;
		  
		  hdTipoConsultaJa = '';
		  
		  if(valor==1)
		  {
		    var dato = document.getElementById(c_campo1).value;  
		    longiBusc = dato.length;

		    var dato1 = document.getElementById(c_campo2).value;  
		    longiBusc1 = dato1.length;

		    
		    if (longiBusc < 3)
		      if(longiBusc1<4)
		      {
		        alert('Ingrese 3 Digitos de la Cedula del Contratista o el Nombre del Contratista');
		        return false;
		      }
		        
		    obtieneListaValores(campo1, campo2, 'consultaContratista');
			
		  }else if(valor==3)
		  {
		    obtieneListaValores(campo1, campo2, 'consultaFiscalizador');
		    
		  }else if(valor==2)
		  {
		    obtieneListaValores(campo1, campo2, 'consultaAdministrador');
		    
		  }else if(valor==4)
		  {
		  obtieneListaValores(campo1, campo2, 'consultaGerencia');
			
		  }else if(valor==5)
		  {
		     hdTipoConsultaJa = document.getElementById('hdTipoConsulta').value;
		     
		     if(hdTipoConsultaJa==1)
		         datoCodContra = '1';  
		     else
		         datoCodContra = '2';  
		         
		     obtieneListaValores(campo1, campo2, 'consultaCodProceso');
		  }
		}
        
        var obj;
              function getXMLHTTPRequest() 
              {
                 var xRequest=null;
                if (window.XMLHttpRequest) {
                xRequest=new XMLHttpRequest();
                }else if (typeof ActiveXObject != "undefined"){
                  xRequest=new ActiveXObject("Microsoft.XMLHTTP");
                }
                  return xRequest;
                }
            function obtieneListaValores(campo1, campo2, campo3)
            {
                obj=getXMLHTTPRequest();
                if(obj!=null)
                {
                    obj.onreadystatechange = ProcessResponse;
                    obj.open("GET", "Srvlets/ProcessedPage.aspx?campo1="+campo1+"&campo2="+campo2+"&campo3="+campo3+"&campo4="+hdTipoConsultaJa,  true);
                    obj.send(null);         
                }
                return false;
            }

            function ProcessResponse()
            {
                var basePath = "";
                
                if(obj.readyState == 4)
                {
                    if(obj.status == 200)
                    {
                        var retval=obj.responseText;  
                        
                        window.open(basePath+'General/encontrarDatos.aspx?exP='+navigator.appName.indexOf("Microsoft")+'&nomCampo1='+nomCampo1+'&nomCampo2='+nomCampo2+'&conServ='+datoCodContra,'Consulta','width=590px,height=300px');

                    }
                    else
                    {
                        alert("Error retrieving data!" );
                    }   
                }
            }
            
             
                function abrirEmailAdmin(nombreUrl)
                {
                    window.open(nombreUrl,'_blank','location=0,status=1,scrollbars=1,width=370,height=180');
                }
                
                
               /* function consuAdministrador(codContrato)
            {
                    mygrid.clearAll(true);                   
                    mygrid.init();
                    mygrid.loadXML("consuXMLAdministrador.aspx?codigoContrato="+codContrato);
            }*/
            
         
         

    </script>

    <style type="text/css">
        .cajaTexto
        {
            font-size: 11px;
            font: Tahoma;
            border-left: #6699CC 1px solid;
            border-bottom: #4167B0 1px solid;
            border-right: #6699CC 1px solid;
            border-top: #4167B0 1px solid;
        }
        .style1
        {
            height: 30px;
            }
        .style2
        {
            height: 30px;
            font-weight: bold;
        }
        .style3
        {}
    
.dxheControl
{
    border: Solid 1px #7f7f7f;
}

.dxtbControl 
{
    font: 9pt Tahoma;
    color: black;
    background-color: #9d9d9d;
    width: 100%;
    border-bottom: Solid 1px #7f7f7f;
}
.dxmMenu,
.dxmVerticalMenu
{
	font: 9pt Tahoma;
	color: black;
	background-color: #F0F0F0;
	border: solid 1px #A8A8A8;
	padding: 2px 2px 2px 2px;
}
.dxmMenuItem,
.dxmMenuItemWithImage
{
	padding: 4px 8px 5px;
}

.dxmMenuItem,
.dxmMenuItemWithImage,
.dxmMenuItemWithPopOutImage,
.dxmMenuItemWithImageWithPopOutImage,
.dxmVerticalMenuItem,
.dxmVerticalMenuItemWithImage,
.dxmVerticalMenuItemWithPopOutImage,
.dxmVerticalMenuItemWithImageWithPopOutImage, 
.dxmVerticalMenuRtlItem,
.dxmVerticalMenuRtlItemWithImage,
.dxmVerticalMenuRtlItemWithPopOutImage,
.dxmVerticalMenuRtlItemWithImageWithPopOutImage,
.dxmMenuLargeItem,
.dxmMenuLargeItemWithImage,
.dxmMenuLargeItemWithPopOutImage,
.dxmMenuLargeItemWithImageWithPopOutImage,
.dxmVerticalMenuLargeItem,
.dxmVerticalMenuLargeItemWithImage,
.dxmVerticalMenuLargeItemWithPopOutImage,
.dxmVerticalMenuLargeItemWithImageWithPopOutImage,
.dxmVerticalMenuLargeRtlItem,
.dxmVerticalMenuLargeRtlItemWithImage,
.dxmVerticalMenuLargeRtlItemWithPopOutImage,
.dxmVerticalMenuLargeRtlItemWithImageWithPopOutImage
{
	font: 9pt Tahoma;
	color: black;
	white-space: nowrap;
}

.dxHtmlEditor_Icons_heCut {
    background-position: -48px -74px;
    width: 16px;
    height: 16px;
}

.dxHtmlEditor_Icons_heCut,
.dxHtmlEditor_Icons_heCutDisabled,
.dxHtmlEditor_Icons_heCopy,
.dxHtmlEditor_Icons_heCopyDisabled,
.dxHtmlEditor_Icons_hePaste,
.dxHtmlEditor_Icons_hePasteDisabled,
.dxHtmlEditor_Icons_hePasteFromWord,
.dxHtmlEditor_Icons_hePasteFromWordDisabled,
.dxHtmlEditor_Icons_heUndo,
.dxHtmlEditor_Icons_heUndoDisabled,
.dxHtmlEditor_Icons_heRedo,
.dxHtmlEditor_Icons_heRedoDisabled,
.dxHtmlEditor_Icons_heBold,
.dxHtmlEditor_Icons_heBoldDisabled,
.dxHtmlEditor_Icons_heItalic,
.dxHtmlEditor_Icons_heItalicDisabled,
.dxHtmlEditor_Icons_heUnderline,
.dxHtmlEditor_Icons_heUnderlineDisabled,
.dxHtmlEditor_Icons_heStrikethrough,
.dxHtmlEditor_Icons_heStrikethroughDisabled,
.dxHtmlEditor_Icons_heCenter,
.dxHtmlEditor_Icons_heCenterDisabled,
.dxHtmlEditor_Icons_heLeft,
.dxHtmlEditor_Icons_heLeftDisabled,
.dxHtmlEditor_Icons_heRight,
.dxHtmlEditor_Icons_heRightDisabled,
.dxHtmlEditor_Icons_heJustifyFull,
.dxHtmlEditor_Icons_heJustifyFullDisabled,
.dxHtmlEditor_Icons_heSuperscript,
.dxHtmlEditor_Icons_heSuperscriptDisabled,
.dxHtmlEditor_Icons_heSubscript,
.dxHtmlEditor_Icons_heSubscriptDisabled,
.dxHtmlEditor_Icons_heIndent,
.dxHtmlEditor_Icons_heIndentDisabled,
.dxHtmlEditor_Icons_heOutdent,
.dxHtmlEditor_Icons_heOutdentDisabled,
.dxHtmlEditor_Icons_heInsertOrderedList,
.dxHtmlEditor_Icons_heInsertOrderedListDisabled,
.dxHtmlEditor_Icons_heInsertUnorderedList,
.dxHtmlEditor_Icons_heInsertUnorderedListDisabled,
.dxHtmlEditor_Icons_heInsertImageDialog,
.dxHtmlEditor_Icons_heInsertImageDialogDisabled,
.dxHtmlEditor_Icons_heInsertLinkDialog,
.dxHtmlEditor_Icons_heInsertLinkDialogDisabled,
.dxHtmlEditor_Icons_heInsertTableDialog,
.dxHtmlEditor_Icons_heInsertTableDialogDisabled,
.dxHtmlEditor_Icons_heChangeTableDialog,
.dxHtmlEditor_Icons_heChangeTableDialogDisabled,
.dxHtmlEditor_Icons_heChangeTableCellDialog,
.dxHtmlEditor_Icons_heChangeTableCellDialogDisabled,
.dxHtmlEditor_Icons_heChangeTableColumnDialog,
.dxHtmlEditor_Icons_heChangeTableColumnDialogDisabled,
.dxHtmlEditor_Icons_heChangeTableRowDialog,
.dxHtmlEditor_Icons_heChangeTableRowDialogDisabled,
.dxHtmlEditor_Icons_heInsertTableRowAbove,
.dxHtmlEditor_Icons_heInsertTableRowAboveDisabled,
.dxHtmlEditor_Icons_heInsertTableRowBelow,
.dxHtmlEditor_Icons_heInsertTableRowBelowDisabled,
.dxHtmlEditor_Icons_heInsertTableColumnOnLeft,
.dxHtmlEditor_Icons_heInsertTableColumnOnLeftDisabled,
.dxHtmlEditor_Icons_heInsertTableColumnOnRight,
.dxHtmlEditor_Icons_heInsertTableColumnOnRightDisabled,
.dxHtmlEditor_Icons_heSplitTableCellHorizontal,
.dxHtmlEditor_Icons_heSplitTableCellHorizontalDisabled,
.dxHtmlEditor_Icons_heSplitTableCellVertical,
.dxHtmlEditor_Icons_heSplitTableCellVerticalDisabled,
.dxHtmlEditor_Icons_heMergeTableCellHorizontal,
.dxHtmlEditor_Icons_heMergeTableCellHorizontalDisabled,
.dxHtmlEditor_Icons_heMergeTableCellVertical,
.dxHtmlEditor_Icons_heMergeTableCellVerticalDisabled,
.dxHtmlEditor_Icons_heDeleteTable,
.dxHtmlEditor_Icons_heDeleteTableDisabled,
.dxHtmlEditor_Icons_heDeleteTableColumn,
.dxHtmlEditor_Icons_heDeleteTableColumnDisabled,
.dxHtmlEditor_Icons_heDeleteTableRow,
.dxHtmlEditor_Icons_heDeleteTableRowDisabled,
.dxHtmlEditor_Icons_heUnlink,
.dxHtmlEditor_Icons_heUnlinkDisabled,
.dxHtmlEditor_Icons_heBackColor,
.dxHtmlEditor_Icons_heBackColorDisabled,
.dxHtmlEditor_Icons_heForeColor,
.dxHtmlEditor_Icons_heForeColorDisabled,
.dxHtmlEditor_Icons_heRemoveFormat,
.dxHtmlEditor_Icons_heRemoveFormatDisabled,
.dxHtmlEditor_Icons_hePrint,
.dxHtmlEditor_Icons_hePrintDisabled,
.dxHtmlEditor_Icons_heCheckSpelling,
.dxHtmlEditor_Icons_heCheckSpellingDisabled,
.dxHtmlEditor_Icons_heFullscreen,
.dxHtmlEditor_heToolbarPopOut,
.dxHtmlEditor_heConstrainProportionsMiddleOn,
.dxHtmlEditor_heConstrainProportionsMiddleOff,
.dxHtmlEditor_heConstrainProportionsBottom,
.dxHtmlEditor_heConstrainProportionsTop,
.dxHtmlEditor_RoundPanel_herpHeaderTopLeftCorner,
.dxHtmlEditor_RoundPanel_herpHeaderTopRightCorner,
.dxHtmlEditor_RoundPanel_herpBottomLeftCorner,
.dxHtmlEditor_RoundPanel_herpBottomRightCorner,
.dxHtmlEditor_RoundPanel_herpTopLeftCorner,
.dxHtmlEditor_RoundPanel_herpTopRightCorner,
.dxHtmlEditor_RoundPanel_herpGroupBoxBottomLeftCorner,
.dxHtmlEditor_RoundPanel_herpGroupBoxBottomRightCorner,
.dxHtmlEditor_RoundPanel_herpGroupBoxTopLeftCorner,
.dxHtmlEditor_RoundPanel_herpGroupBoxTopRightCorner,
.dxHtmlEditor_heSizeGrip,
.dxHtmlEditor_heErrorFrameCloseButton
 {
    background-repeat: no-repeat;
    background-color: transparent;
}

.dxmMenuItemSpacing,
.dxmMenuLargeItemSpacing,
.dxmMenuItemSeparatorSpacing,
.dxmMenuLargeItemSeparatorSpacing
{
	width: 2px;	
}

.dxHtmlEditor_Icons_heCopy {
    background-position: 0px -74px;
    width: 16px;
    height: 16px;
}

.dxHtmlEditor_Icons_hePaste {
    background-position: -96px -194px;
    width: 16px;
    height: 16px;
}

.dxHtmlEditor_Icons_hePasteFromWord {
    background-position: -144px -194px;
    width: 16px;
    height: 16px;
}

.dxmMenuFullHeightSeparator
{
	display: none;
}

.dxmMenuSeparator .dx,
.dxmMenuFullHeightSeparator,
.dxmMenuVerticalSeparator
{
	background-color: #A8A8A8;
	width: 1px;
}
.dxmMenuSeparator,
.dxmMenuFullHeightSeparator
{
	width: 1px;
}

.dxmMenuSeparator .dx,
.dxmMenuFullHeightSeparator .dx 
{
	font-size: 0;
	line-height: 0;
	overflow: hidden;
	width: 1px;
	height: 1px;
}

.dxHtmlEditor_Icons_heUndo {
    background-position: -96px -266px;
    width: 16px;
    height: 16px;
}

.dxHtmlEditor_Icons_heRedo {
    background-position: -48px -218px;
    width: 16px;
    height: 16px;
}

.dxHtmlEditor_Icons_heRemoveFormat {
    background-position: -96px -218px;
    width: 16px;
    height: 16px;
}

.dxHtmlEditor_Icons_heSuperscript {
    background-position: 0px -266px;
    width: 16px;
    height: 16px;
}

.dxHtmlEditor_Icons_heSubscript {
    background-position: -144px -242px;
    width: 16px;
    height: 16px;
}

.dxHtmlEditor_Icons_heInsertOrderedList {
    background-position: -48px -122px;
    width: 16px;
    height: 16px;
}

.dxHtmlEditor_Icons_heInsertUnorderedList {
    background-position: -144px -146px;
    width: 16px;
    height: 16px;
}

.dxHtmlEditor_Icons_heIndent {
    background-position: -96px -98px;
    width: 16px;
    height: 16px;
}

.dxHtmlEditor_Icons_heOutdent {
    background-position: -48px -194px;
    width: 16px;
    height: 16px;
}

.dxHtmlEditor_Icons_heInsertLinkDialog {
    background-position: 0px -122px;
    width: 16px;
    height: 16px;
}

.dxHtmlEditor_Icons_heUnlink {
    background-position: -144px -266px;
    width: 16px;
    height: 16px;
}

.dxHtmlEditor_Icons_heInsertImageDialog {
    background-position: -144px -98px;
    width: 16px;
    height: 16px;
}

.dxmMenuItemWithPopOutImage,
.dxmMenuItemWithImageWithPopOutImage
{
	padding: 4px 6px 5px 8px;
}	

.dxHtmlEditor_Icons_heInsertTableDialog {
    background-position: 0px -146px;
    width: 16px;
    height: 16px;
}

.dxmMenuItemDropDownButton,
.dxmMenuLargeItemDropDownButton
{
	padding-right: 5px;
	padding-left: 5px;
}

.dxHtmlEditor_heToolbarPopOut {
    background-position: -135px 0px;
    width: 5px;
    height: 3px;
}

.dxHtmlEditor_Icons_heFullscreen 
{
    background-position: -24px -290px;
    width: 16px;
    height: 16px;
}

.dxmSubMenuBorderCorrector
{
    position: absolute;
    border: 0px;
    padding: 0px;
}

.dxmSubMenu
{
	font: 9pt Tahoma;
	color: black;
	background-color: white;
	border: solid 1px #666666;
	padding: 1px;
}
.dxtbSpacing
{
	height: 1px;
}
.dxtbComboBoxMenuItem
{
    padding-top: 2px;
}

.dxeButtonEdit
{
    background-color: white;
    border: solid 1px #9F9F9F;
    width: 170px;
}
.dxeButtonEdit .dxeEditArea {
    background-color: white;
}

.dxeEditArea 
{
	font-family: Tahoma;
	font-size: 9pt;
	border: 1px solid #A0A0A0;
}

.dxeEditAreaSys
{
	border: 0px!important;
	padding: 0px;
	width: 100%;
}

.dxeButtonEditButton,
.dxeSpinIncButton,
.dxeSpinDecButton,
.dxeSpinLargeIncButton,
.dxeSpinLargeDecButton
{
    padding: 0px 2px 0px 3px;
	background-repeat: repeat-x;
    background-position: top;    
    background-color: #e6e6e6;
}
.dxeButtonEditButton,
.dxeCalendarButton,
.dxeSpinIncButton,
.dxeSpinDecButton,
.dxeSpinLargeIncButton,
.dxeSpinLargeDecButton
{	
	vertical-align: middle;
	border: solid 1px #7f7f7f;
	cursor: pointer;
} 

.dxEditors_edtDropDown {
    background-position: -95px 0px;
    width: 10px;
    height: 14px;
}

.dxEditors_edtError,
.dxEditors_edtCalendarPrevYear,
.dxEditors_edtCalendarPrevYearDisabled,
.dxEditors_edtCalendarPrevMonth,
.dxEditors_edtCalendarPrevMonthDisabled,
.dxEditors_edtCalendarNextMonth,
.dxEditors_edtCalendarNextMonthDisabled,
.dxEditors_edtCalendarNextYear,
.dxEditors_edtCalendarNextYearDisabled,
.dxEditors_edtCalendarFNPrevYear,
.dxEditors_edtCalendarFNNextYear,
.dxEditors_edtCheckBoxOn,
.dxEditors_edtCheckBoxOff,
.dxEditors_edtCheckBoxUndefined,
.dxEditors_edtRadioButtonOn,
.dxEditors_edtRadioButtonOff,
.dxEditors_edtRadioButtonUndefined,
.dxEditors_edtEllipsis,
.dxEditors_edtEllipsisDisabled,
.dxEditors_edtDropDown,
.dxEditors_edtDropDownDisabled,
.dxEditors_edtSpinEditIncrementImage,
.dxEditors_edtSpinEditIncrementImageDisabled,
.dxEditors_edtSpinEditDecrementImage,
.dxEditors_edtSpinEditDecrementImageDisabled,
.dxEditors_edtSpinEditLargeIncImage,
.dxEditors_edtSpinEditLargeIncImageDisabled,
.dxEditors_edtSpinEditLargeDecImage,
.dxEditors_edtSpinEditLargeDecImageDisabled,
.dxEditors_fcadd,
.dxEditors_fcaddhot,
.dxEditors_fcremove,
.dxEditors_fcremovehot,
.dxEditors_fcgroupaddcondition,
.dxEditors_fcgroupaddgroup,
.dxEditors_fcgroupremove,
.dxEditors_fcopany,
.dxEditors_fcopbegin,
.dxEditors_fcopbetween,
.dxEditors_fcopcontain,
.dxEditors_fcopnotcontain,
.dxEditors_fcopnotequal,
.dxEditors_fcopend,
.dxEditors_fcopequal,
.dxEditors_fcopgreater,
.dxEditors_fcopgreaterorequal,
.dxEditors_fcopnotblank,
.dxEditors_fcopblank,
.dxEditors_fcopless,
.dxEditors_fcoplessorequal,
.dxEditors_fcoplike,
.dxEditors_fcopnotany,
.dxEditors_fcopnotbetween,
.dxEditors_fcopnotlike,
.dxEditors_fcgroupand,
.dxEditors_fcgroupor,
.dxEditors_fcgroupnotand,
.dxEditors_fcgroupnotor,
.dxEditors_caRefresh {
    background-repeat: no-repeat;
    background-color: transparent;
}

.dxHtmlEditor_Icons_heBold {
    background-position: -48px -26px;
    width: 16px;
    height: 16px;
}

.dxHtmlEditor_Icons_heItalic {
    background-position: 0px -170px;
    width: 16px;
    height: 16px;
}

.dxHtmlEditor_Icons_heUnderline {
    background-position: -48px -266px;
    width: 16px;
    height: 16px;
}

.dxHtmlEditor_Icons_heStrikethrough {
    background-position: -96px -242px;
    width: 16px;
    height: 16px;
}

.dxHtmlEditor_Icons_heLeft {
    background-position: -96px -170px;
    width: 16px;
    height: 16px;
}

.dxHtmlEditor_Icons_heCenter {
    background-position: -96px -26px;
    width: 16px;
    height: 16px;
}

.dxHtmlEditor_Icons_heRight {
    background-position: -144px -218px;
    width: 16px;
    height: 16px;
}

.dxHtmlEditor_Icons_heJustifyFull {
    background-position: -48px -170px;
    width: 16px;
    height: 16px;
}

.dxHtmlEditor_Icons_heBackColor {
    background-position: 0px -26px;
    width: 16px;
    height: 13px;
}

.dxtcbColorDiv
{
	width: 16px;
	height: 3px;
	font-size:0pt;
	background-color: Transparent;
}

.dxHtmlEditor_Icons_heForeColor {
    background-position: -48px -98px;
    width: 16px;
    height: 13px;
}

.dxheContentArea
{
    padding: 4px;
    padding-bottom: 6px;    
    background-color: #cecece;
}
.dxheHtmlViewArea,
.dxheDesignViewArea,
.dxhePreviewArea 
{
    margin: 0px;
    background-color: #FFFFFF;
    background-image: none;
    text-align: left;
    font-size: smaller;
    font: normal 12px Arial;    
}
.dxheViewArea
{
    border: Solid 1px #a8a8a8;    
}
.dxtcControl 
{
	font: 9pt Tahoma;
	color: black;
}
.dxheStatusBarTab 
{
    padding-left: 11px;
    padding-right: 12px;
    padding-bottom: 5px;
}

.dxtcActiveTab,
.dxtcActiveTabWithTabPositionBottom,
.dxtcActiveTabWithTabPositionLeft,
.dxtcActiveTabWithTabPositionRight
{
	font: 9pt Tahoma;
	color: black;
	border: solid 1px #A8A8A8;
	padding: 3px 12px 4px 12px;
	background-color: #FFFFFF;
	text-align: center;
}
.dxtcTab,
.dxtcTabWithTabPositionLeft, 
.dxtcTabWithTabPositionBottom,
.dxtcTabWithTabPositionRight
{
	font: 9pt Tahoma;
	color: black;
	background-color: #E0E0E0;
	border: solid 1px #A8A8A8;
	padding: 3px 12px 4px 12px;
	text-align: center;
}
.dxtcRightAlignCell,
.dxtcTabsCellWithTabPositionBottom .dxtcRightAlignCell 
{
	text-align: right;
}
        </style>
</head>
<body>
    <form id="form1" runat="server">
      <!--<table style="width: 100%" cellspacing="0" cols="0" cellpadding="0">
            <tr>
                <td align="left" valign="bottom" style="width: 80%">
                    <span style="height: 35px; font-weight: bold; font-size: 18px; color: #3A5389; font-family: Tahoma;">
                        </span>
                </td>
            </tr>
        </table>-->
        
    <table bgcolor="#EAF3FF" style="width: 100%; font-size: 11px; font-family: Tahoma;
            border-right: #b0c2d0 1px solid; border-top: #b0c2d0 1px solid; border-left: #b0c2d0 1px solid;
            border-bottom: #b0c2d0 1px solid">
        <tr>
            <td style="padding-right: 2px; padding-left: 5px; font-size:11px;"
									nowrap="nowrap" class="style1">Administrador:</td> 
								<td class="style3">
                                    <table cellpadding="0" cellspacing="0">
                                        <tr>
                                            <td>
                                                
                                                <asp:TextBox ID="ContxtAdministrador" runat="server" CssClass="cajaTexto" 
                                                    MaxLength="14" Width="100px" ></asp:TextBox>
                                            </td>
                                            <td>
                                                <asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" 
                                                    ControlToValidate="ContxtAdministrador" ErrorMessage="Ingrese el Cod. Adm.">*</asp:RequiredFieldValidator>
                                            </td>
                                            <td>
                                                <asp:TextBox ID="ContxtDescAdministrador" runat="server" CssClass="cajaTexto" 
                                                    MaxLength="40" Width="250px" ></asp:TextBox>
                                            </td>
                                            <td>
                                                <asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" 
                                                    ControlToValidate="ContxtDescAdministrador" 
                                                    ErrorMessage="Ingrese el Nombre del Adm.">*</asp:RequiredFieldValidator>
                                                <asp:ImageButton ID="imgAdministrador" runat="server" CausesValidation="False" 
                                                    ImageUrl="images/ico_18_126.gif" 
                                                    OnClientClick="abrirPopup('ContxtAdministrador','ContxtDescAdministrador',2);return false;" 
                                                    Width="16px" >
                                                </asp:ImageButton>
                                            </td>
                                            <td></td>
                                            <td>
                                                &nbsp;</td>
                                        </tr>
                                    </table>
                                  </td> 
								<td style="width: 41%">
                                 <asp:ImageButton ID="imgAgregaAdministra" runat="server" 
                                                    ImageUrl="~/images/ico_48_languages.gif" 
                                        onclick="imgAgregaAdministra_Click"/>
                                  </td> 
                                 <td>
                                     &nbsp;</td>
        </tr>
        
        <tr>
        <td style="padding-right: 2px; padding-left: 5px; font-size:11px;"
									nowrap="nowrap" class="style1">Tipo de Asignacion:</td> 
							<td class="style3">
							    <asp:DropDownList ID="dpTipoAsignacion" runat="server" CssClass="cajaTexto" 
                                    DataSourceID="SqlDataSource1" DataTextField="CATALOGO_DESCRIPCION" 
                                    DataValueField="CATALOGO_CODIGO" Height="16px" Width="215px">
                                </asp:DropDownList>
                                <asp:SqlDataSource ID="SqlDataSource1" runat="server" 
                                    ConnectionString="<%$ ConnectionStrings:ConnectionString3 %>" 
                                    ProviderName="<%$ ConnectionStrings:ConnectionString3.ProviderName %>" SelectCommand="     select CATALOGO_CODIGO, CATALOGO_DESCRIPCION from web_catalogo where catalogo_nombre = 'TIPADMI'
     ORDER BY CATALOGO_CODIGO"></asp:SqlDataSource>
							    <asp:HiddenField ID="txtCodContrato" runat="server" />
							    <asp:HiddenField ID="txtCodProceso" runat="server" />
                                <asp:HiddenField ID="txtObjetoContrato" runat="server" />
							</td>
            
							<td>
							    &nbsp;</td>
            
        </tr>
        
        <tr>
        <td style="padding-right: 2px; padding-left: 5px; font-size:11px;"
									nowrap="nowrap" class="style1">Observacion:</td> 
							<td class="style3">
							    <asp:TextBox ID="txtObservacion" runat="server" CssClass="cajaTexto" 
                                    Height="48px" TextMode="MultiLine" Width="398px"></asp:TextBox>
							</td>
            
							<td>
							    <asp:ValidationSummary ID="ValidationSummary1" runat="server" />
							</td>
            
        </tr>
        
        <tr>
        <td style="padding-right: 2px; padding-left: 5px; font-size:11px;"
									nowrap="nowrap" class="style2" colspan="3">Datos 
            adjuntos de la Asginacion</td> 
            
        </tr>
        
        <tr>
        <td style="padding-right: 2px; padding-left: 5px; font-size:11px;"
									nowrap="nowrap" class="style1">Archivo Adjunto:</td> 
							<td class="style3">
							   <table>
							     <tr>
							      <td>							    
							    <asp:FileUpload ID="FileUpload1" runat="server" CssClass="cajaTexto" 
                                    Width="274px" />
                                  </td>
                                  <td>
                                      <asp:ImageButton ID="imgAgregarArch" runat="server" CausesValidation="False" 
                                          ImageUrl="~/images/16_runworkflow.gif" onclick="imgAgregarArch_Click" />
                                     </td>
                                     <td>
							    <asp:ListBox ID="lstArchivos" runat="server" CssClass="cajaTexto" Height="49px" 
                                    Width="171px"></asp:ListBox>
                                     </td>
                                 </tr>
                                </table>
							</td>
            
							<td>
							    &nbsp;</td>
            
        </tr>
        
        <tr>
        <td style="padding-right: 2px; padding-left: 5px; font-size:11px;"
									nowrap="nowrap" class="style1">Email a Enviar:</td> 
							<td class="style3" colspan="2">
							  <table>
							    <tr>
							     <td>
							         <asp:LinkButton ID="LinkButton1" runat="server" onclick="LinkButton1_Click" 
                                         CausesValidation="False">Ver Informacion del Email</asp:LinkButton>
                                </td>
                                  <td></td>
                                  <td>&nbsp;</td>
                                </tr>
                                </table>
							</td>
            
        </tr>
        
        <tr>
           <td colspan="4">
               <dx:ASPxHtmlEditor ID="ASPxHtmlEditor1" runat="server" Visible="False">
<SettingsImageSelector>
<CommonSettings AllowedFileExtensions=".jpe, .jpeg, .jpg, .gif, .png"></CommonSettings>
</SettingsImageSelector>

<SettingsImageUpload>
<ValidationSettings AllowedFileExtensions=".jpe, .jpeg, .jpg, .gif, .png"></ValidationSettings>
</SettingsImageUpload>
               </dx:ASPxHtmlEditor>
           </td>
        </tr>
        
        <tr>
           <td colspan="4">
            <div id="divAdministrador" runat="server" style="width:auto;height:170px;background-color:white;overflow:hidden">					 		
			</div>	
           </td>
        </tr>
    </table>
    
    
    <script type="text/javascript">
  
	   try
	   {
	   mygrid = new dhtmlXGridObject('divAdministrador');
							mygrid.setImagePath("js/dhtmlGRID/codebase/imgs/");
							mygrid.setColumnIds("A, Cedula,Nombres,Apellido,estadoCivil,fechaIngreso");
							mygrid.setHeader("Id Adm,Codigo de Contrato,Cod Usuario,Nombre de Usuario, Observacion, Tipo de Asignacion");
							mygrid.setInitWidths("50,100,100,150,250,150,150,150,150")
							mygrid.setColAlign("right,right,left,left,left,left,left,left,left")
							mygrid.setColTypes("ro,ro,ro,ro,ro,ro,ro,ro,ro,ro");
							mygrid.setSkin("dhx_skyblue");
							mygrid.setColSorting("int,str,str,str,str,str,str,str,str,str")
							mygrid.init();
							
                   
                   // mygrid.loadXML("consuXmlGaran.aspx?codigoContrato=1");							
		}catch(e2)
				{
				  //alert(e2);
				}		
		
		
		   function consuAdministrador(rutaActa)
         {
         try
            {
            mygrid.loadXML(rutaActa);
            }catch(e1)
            {
               // alert(e1);
            }
         }
		
    </script>
    
    </form>
</body>
</html>
